﻿CREATE TABLE [dbo].[PropunereAngajareCheltuiala] (
    [IDPAC]            INT             IDENTITY (1, 1) NOT NULL,
    [Numar]            VARCHAR (20)    NOT NULL,
    [Data]             DATETIME        CONSTRAINT [DF_PropunereAngajareCheltuiala_Data] DEFAULT (getdate()) NOT NULL,
    [Compartiment]     VARCHAR (250)   CONSTRAINT [DF_PropunereAngajareCheltuiala_Compartiment] DEFAULT ('') NOT NULL,
    [Scopul]           VARCHAR (250)   CONSTRAINT [DF_PropunereAngajareCheltuiala_Scopul] DEFAULT ('') NOT NULL,
    [Beneficiarul]     VARCHAR (250)   CONSTRAINT [DF_PropunereAngajareCheltuiala_Beneficiarul] DEFAULT ('') NOT NULL,
    [CodUnitate]       SMALLINT        CONSTRAINT [DF_PropunereAngajareCheltuiala_CodUnitate] DEFAULT ((0)) NOT NULL,
    [SumaTotala]       DECIMAL (18, 2) CONSTRAINT [DF_PropunereAngajareCheltuiala_Suma] DEFAULT ((0)) NOT NULL,
    [VizatCFP]         BIT             CONSTRAINT [DF_PropunereAngajareCheltuiala_VizatCFP] DEFAULT ((0)) NOT NULL,
    [MotivRefuz]       VARCHAR (250)   CONSTRAINT [DF_PropunereAngajareCheltuiala_MotivRefuz] DEFAULT ('') NOT NULL,
    [IDResponsabil]    INT             CONSTRAINT [DF_PropunereAngajareCheltuiala_IDResponsabil] DEFAULT ((0)) NOT NULL,
    [DataVizaCFP]      DATETIME        CONSTRAINT [DF_PropunereAngajareCheltuiala_DataVizaCFP] DEFAULT (getdate()) NOT NULL,
    [NrRegCFP]         VARCHAR (20)    CONSTRAINT [DF_PropunereAngajareCheltuiala_NrRegCFP] DEFAULT ('') NOT NULL,
    [OrdonatorCredite] VARCHAR (100)   CONSTRAINT [DF_PropunereAngajareCheltuiala_OrdonatorCredite] DEFAULT ('') NOT NULL,
    CONSTRAINT [PK_PropunereAngajareCheltuiala] PRIMARY KEY CLUSTERED ([IDPAC] ASC),
    CONSTRAINT [FK_PropunereAngajareCheltuiala_ResponsabilVizaCFP] FOREIGN KEY ([IDResponsabil]) REFERENCES [dbo].[ResponsabilVizaCFP] ([IDResponsabil]),
    CONSTRAINT [FK_PropunereAngajareCheltuiala_Unitati] FOREIGN KEY ([CodUnitate]) REFERENCES [dbo].[Unitati] ([CodUnitate])
);

